#pragma  once
#include "Aobj.h"

class AconfigFileStuff;
class AconfigFile : public Aobj
{
private:
	AconfigFileStuff * mstuff;
public:
	AconfigFile();
	~AconfigFile() ;

	void test();

	void setFilename( CString s );
	void setDir( CString s );// end without "\";
	void setSection( CString s );
	bool updatePath();

	bool isEixst() ;
	int createFile();
	int writeStr( CString str );

	CString GetStr( CString key );
	CString GetStrDef( CString key, CString dsv );
	CString GetString( CString section, CString key );
	CString GetStringDef(CString section, CString key, CString dsv );
	
	int GetInt( CString key, int dv );
	int GetInt( CString section, CString key, int dv );

	void SetStr( CString key, CString val );
	void SetStr( CString section, CString key, CString val );

	bool setInt(CString sec, CString key, int val ) ;
	bool setInt(CString key, int val);
};
